package com.gmail.at.dao;

import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;
import org.springframework.data.repository.query.Param;

import com.gmail.at.model.Passenger;
import com.gmail.at.model.Role;

public interface RoleDAO extends CrudRepository<Role, Integer> {
	
	@Query("select r from Role r where r.passenger = :passenger")
    public Role findByPassenger(@Param("passenger") Passenger passenger);

}
